<?php




/**
* Details of an entry in [ identifiers ]
*/

$identifiers = new identifiers();
$identifier_id = $variable->get('id', 'integer', 0); # Entity ID
$code = $variable->get('code', 'string', ''); # Protection Code

if(!$identifier_id || !$code)
{
	# Page was loaded without the ID parementer
	stopper::url('identifiers-direct-access-error.php?context=identity');
}
else
{
	# Check for valid requests
	# if(!$identifiers->is_valid($identifier_id, $code)) stopper::message('Invalid request.', false);
	
	# Try to load the details
	if($identifiers_details = $identifiers->details($identifier_id, $code))
	{
		# We aim to reach here only.
		$smarty->assignByRef('identifiers', $identifiers_details);
	}
	else
	{
		# Record not found
		stopper::url('identifiers-direct-access-error.php?context=data');
	}
}
?>